match remote_message.message_type.as_str() {
    "system.watch" => {
        let sender = remote_message.sender.unwrap_or_default();
        let sender_pid = PID::new(sender.address, sender.id);
        
        let (tx, _) = std::sync::mpsc::channel::<PID>();
        
        let watch = SystemMessage::Watch(tx);
        
        let process = self.system.get_local_process(target);
        if let Some(process) = process {
            process.send_system_message(watch);
        }
    }
    "system.unwatch" => {
        let sender = remote_message.sender.unwrap_or_default();
        let sender_pid = PID::new(sender.address, sender.id);
        
        let (tx, _) = std::sync::mpsc::channel::<PID>();
        
        let unwatch = SystemMessage::Unwatch(tx);
        
        let process = self.system.get_local_process(target);
        if let Some(process) = process {
            process.send_system_message(unwatch);
        }
    }
    "system.stop" => {
        let stop = SystemMessage::Stop;
        
        let process = self.system.get_local_process(target);
        if let Some(process) = process {
            process.send_system_message(stop);
        }
    }
    _ => {
        if let Some(message) = remote_message.message {
            if let Err(err) = self.system.send(&target, message).await {
                error!("Failed to deliver remote message: {}", err);
            }
        } else {
            warn!("Received empty message for {}", target);
        }
    }
} 